<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
	<%@ page isELIgnored="false"%>
	<%@ taglib uri="/struts-tags" prefix="s"%>
	<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>用户中心</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link href="${pageContext.request.contextPath}/styles/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery.js"></script>
<noscript ><meta http-equiv="refresh" content="5;url=nojs.html"><div style="text-align:center;color:red;">对不起！请启用js才能正常浏览！</div></noscript> 
<script type="text/javascript" charset="utf-8">

$(document).ready(function(){
	/*初始化的情况*/
	 $(".admin_menu_user").first().css("background-color","#258DCD");
	 $("form").first().show();
	 
	 /*按钮点击响应函数 来隐藏点东西*/ 
	 $(".admin_menu_user").each(function(index){
		      $(this).click(function(){
				   $(".admin_menu_user").each(function(){
					     $(this).css("background-color","#FFFFFF");;
					   });
				   $(this).css("background-color","#258DCD");
				   $("form").each(function(){
					      $(this).hide();
					   });
				    $("form").eq(index).show();
				    return false;
				  });
		 });
});
</script>
</head>
<body>
<div class="main">
  <div class="slider2">
    <div class="slider4_resize">
      <h2>用户中心</h2>
    </div>
    <div class="clr"> </div>
  </div>
  <div class="clr"> </div>
  <div class="body">
    <div class="body_resize2">
       <div id="contactform_2">
     
        <ol>
        <li> <img src="${pageContext.request.contextPath}/${user.us_image}" width="60" height="60" align="top" /> ${user.us_nickname}的账号管理</li>
        <li>
            <label > 
                     <input type="button" value="基本信息" class="admin_menu_user" /> 
                     <input type="button" value="密码修改" class="admin_menu_user" /> 
            </label>
        </li>
        </ol>
	  
	    <s:form action="change_baseuser" method="post" id="contactform" style="display:none">
        <ol>
        <li>
            <label ><span class="red0"><s:actionerror/></span></label>
         </li>
         <li style="display:none">
            <label ></label>
            <s:textfield   Class="text" name="user.us_id" />
          </li>
		   <li>
            <label for="email">邮箱:<span class="red1"></span></label>
            <s:textfield id="email"  Class="text" name="email" />
          </li>
          <li>
            <label for="name">昵称:<span class="red2"></span></label>
             <s:textfield id="name" Class="text" name="user.us_nickname"/>
          </li>
           <li>
            <label for="state">用户类型<span class="red3"></span></label>
            <s:select name="us_type" list="#{'5':'普通用户','4':'管理员','0':'超级管理员'}">
            </s:select>
          </li>
         
		  <li class="buttons">
            <input type="submit" value="修改" />
		 </li>
        </ol>
      
	  </s:form>
	    
	    <s:form action="change_password"  method="post"  style="display:none">
        <ol>
        <li>
            <label ><span class="red0"></span></label>
         </li>
          <li style="display:none">
            <label ></label>
            <s:textfield   Class="text" name="user.us_id" />
          </li>
           <li>
            <label for="password2">修改密码<span class="red4"></span></label>
            <s:password id="password2"  Class="text" name="user.us_password" />
          </li> 
		  <li class="buttons">
            <input type="submit" value="修改密码" />
		 </li>
        </ol>   
	  </s:form>
	   
	   
	 
    </div>
    <div class="clr"></div>
    </div>
  </div>
 
</div>
</body>
</html>
